<div class="row">
  <div class="col-md-12">
    <nav class="navbar navbar-default" role="navigation">
      <div class="container-fluid">
        <div class="navbar-header">
          <a class="navbar-brand" href="#">Cached</a>
          <p class="navbar-text">
            Alfresco
            <span class="badge" tooltip-placement="bottom" tooltip="{{ alfrescoOrphansModified | date:'yyyy-MM-dd HH:mm:ss' }}">{{ alfrescoOrphans ? alfrescoOrphans.length : 'cache empty' }}</span>
          </p>
          <p class="navbar-text">
            Solr
            <span class="badge" tooltip-placement="bottom" tooltip="{{ solrOrphansModified | date:'yyyy-MM-dd HH:mm:ss' }}">{{ solrOrphans ? solrOrphans.length : 'cache empty' }}</span>
          </p>
          <!--
          <p class="navbar-text">Solr iFeed <span class="badge">{{ solrIfeedNodes ? solrIfeedNodes.length : 'cache empty' }}</span>
          </p>
          -->
          <button type="button" class="btn btn-default navbar-btn pull-right" ng-click="refresh()">Refresh</button>
        </div>
      </div>
    </nav>
  </div>
</div>

<div class="row" ng-hide="$data.length === 0" ng-cloak>
  <div class="col-md-6">
    <table ng-table="alfrescoOrphansTableParameters" class="table table-striped table-bordered">
      <tr ng-repeat="node in $data" ng-class="node.repushed ? 'repushed' : ''">
        <td data-title="'Alfresco'">
          {{ node.nodeRef }}
          <a style="cursor: pointer;" ng-click="getMetadata(node)" title="Info">
            <span class="document-action glyphicon glyphicon-list-alt pull-right" aria-hidden="true"></span>
          </a>
          <a style="cursor: pointer;" ng-click="repush(node)" title="Repush">
            <span class="document-action glyphicon glyphicon-repeat pull-right" aria-hidden="true"></span>
          </a>
        </td>
      </tr>
    </table>
  </div>
  <div class="col-md-6">
    <table ng-table="solrOrphansTableParameters" class="table table-striped table-bordered">
      <tr ng-repeat="node in $data" ng-class="node.repushed ? 'repushed' : ''">
        <td data-title="'Solr'">
          <span class="glyphicon glyphicon-warning-sign" aria-hidden="true" ng-hide="node.exists" title="Document does not exist in Alfresco"></span>
          {{ node.nodeRef }}
          <a style="cursor: pointer;" ng-click="getMetadata(node)" title="Info">
            <span class="document-action glyphicon glyphicon-list-alt pull-right" aria-hidden="true"></span>
          </a>
          <a style="cursor: pointer;" ng-click="repush(node)" title="Repush">
            <span class="document-action glyphicon glyphicon-repeat pull-right" aria-hidden="true"></span>
          </a>
        </td>
      </tr>
    </table>
  </div>
</div>

<div class="row" ng-hide="$data.length !== 0" ng-cloak>
  <div class="col-md-12">
    No data found!
  </div>
</div>